package com.itheima.stock.service.impl;

import com.itheima.stock.mapper.StockBusinessMapper;
import com.itheima.stock.pojo.StockBusiness;
import com.itheima.stock.service.StockService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author byzhao
 * @version 1.0
 * @description 股票业务实现类
 * @date 2022/10/12 16:05:18
 */
@Service
public class StockServiceImpl implements StockService {

    @Autowired
    private StockBusinessMapper stockBusinessMapper;

    @Override
    public List<StockBusiness> getAllStockBusiness() {
        // 1. 参数校验

        // 2. 核心业务逻辑
        List<StockBusiness> stockBusinessList = stockBusinessMapper.selectAll();

        // 3. 数据封装

        return stockBusinessList;
    }
}
